When a number is not a nubmer, don't just crash, exit properly with an
error code.
See attached testcase for an example.
GTK_CSS_POSITIVE_ONLY
| (values[1] == NULL ? GTK_CSS_PARSE_NUMBER : 0)
| (values[3] == NULL ? GTK_CSS_PARSE_TIME : 0));
+ if (value == NULL)
+ return FALSE;
+
if (_gtk_css_number_value_get_unit (value) == GTK_CSS_NUMBER)
values[1] = value;
else if (values[2] == NULL)
rm $(builddir)/*.out.css || true
test_data = \
+ animation-crash-3.12.css \
+ animation-crash-3.12.errors \
+ animation-crash-3.12.ref.css \
animation-shorthand-crash.css \
animation-shorthand-crash.ref.css \
at-invalid-01.css \
--- /dev/null
+* {
+ animation: 2gra;
+}
--- /dev/null
+animation-crash-3.12.css:2: error: GTK_CSS_PROVIDER_ERROR_SYNTAX